<!DOCTYPE html>
<html><head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title>test-pim.mod</title>
<meta name="generator" content="KF5::SyntaxHighlighting - Definition (Modula-2 (PIM only)) - Theme (Breeze Dark)"/>
</head><body style="background-color:#232629;color:#cfcfc2"><pre>
<span style="color:#7a7c7d;font-style:italic;">(* PIM Modula-2 Syntax highlighting test *)</span>

<span style="color:#7a7c7d;font-style:italic;">(* dialect tags *)</span>

<span style="color:#7a7c7d;font-weight:bold;">(*!m2pim*)</span>


<span style="color:#7a7c7d;font-style:italic;">(* pragmas *)</span>

<span style="color:#27ae60;font-weight:bold;">(*$foo*)</span>


<span style="color:#7a7c7d;font-style:italic;">(* foldable comments *)</span>

<span style="color:#7a7c7d;font-style:italic;">(* foo bar baz</span>
<span style="color:#7a7c7d;font-style:italic;">   (* nested comment *)</span>
<span style="color:#7a7c7d;font-style:italic;">   bam boo bee bop *)</span>


<span style="color:#7a7c7d;font-style:italic;">(* reserved words *)</span>

<span style="font-weight:bold;">AND</span> <span style="font-weight:bold;">ARRAY</span> <span style="font-weight:bold;">BEGIN</span> <span style="font-weight:bold;">BY</span> <span style="font-weight:bold;">CASE</span> <span style="font-weight:bold;">CONST</span> <span style="font-weight:bold;">DEFINITION</span> <span style="font-weight:bold;">DIV</span> <span style="font-weight:bold;">DO</span> <span style="font-weight:bold;">ELSE</span> <span style="font-weight:bold;">ELSIF</span> <span style="font-weight:bold;">END</span> <span style="font-weight:bold;">EXIT</span> <span style="font-weight:bold;">EXPORT</span> <span style="font-weight:bold;">FOR</span>
<span style="font-weight:bold;">FROM</span> <span style="font-weight:bold;">IF</span> <span style="font-weight:bold;">IMPLEMENTATION</span> <span style="font-weight:bold;">IMPORT</span> <span style="font-weight:bold;">IN</span> <span style="font-weight:bold;">LOOP</span> <span style="font-weight:bold;">MOD</span> <span style="font-weight:bold;">MODULE</span> <span style="font-weight:bold;">NOT</span> <span style="font-weight:bold;">OF</span> <span style="font-weight:bold;">OR</span> <span style="font-weight:bold;">POINTER</span> <span style="font-weight:bold;">PROCEDURE</span>
<span style="font-weight:bold;">QUALIFIED</span> <span style="font-weight:bold;">RECORD</span> <span style="font-weight:bold;">REPEAT</span> <span style="font-weight:bold;">RETURN</span> <span style="font-weight:bold;">SET</span> <span style="font-weight:bold;">THEN</span> <span style="font-weight:bold;">TO</span> <span style="font-weight:bold;">TYPE</span> <span style="font-weight:bold;">UNTIL</span> <span style="font-weight:bold;">VAR</span> <span style="font-weight:bold;">WHILE</span> <span style="font-weight:bold;">WITH</span>


<span style="color:#7a7c7d;font-style:italic;">(* built-in constants *)</span>

<span style="color:#7f8c8d;font-weight:bold;">FALSE</span> <span style="color:#7f8c8d;font-weight:bold;">NIL</span> <span style="color:#7f8c8d;font-weight:bold;">TRUE</span>


<span style="color:#7a7c7d;font-style:italic;">(* built-in types *)</span>

<span style="color:#2980b9;font-weight:bold;">BOOLEAN</span> <span style="color:#2980b9;font-weight:bold;">BITSET</span> <span style="color:#2980b9;font-weight:bold;">CARDINAL</span> <span style="color:#2980b9;font-weight:bold;">CHAR</span> <span style="color:#2980b9;font-weight:bold;">INTEGER</span> <span style="color:#2980b9;font-weight:bold;">LONGINT</span> <span style="color:#2980b9;font-weight:bold;">LONGREAL</span> <span style="color:#2980b9;font-weight:bold;">PROC</span> <span style="color:#2980b9;font-weight:bold;">REAL</span>


<span style="color:#7a7c7d;font-style:italic;">(* built-in procedures *)</span>

<span style="color:#7f8c8d;font-weight:bold;">ABS</span> <span style="color:#7f8c8d;font-weight:bold;">ALLOCATE</span> <span style="color:#7f8c8d;font-weight:bold;">CAP</span> <span style="color:#7f8c8d;font-weight:bold;">CHR</span> <span style="color:#7f8c8d;font-weight:bold;">DEALLOCATE</span> <span style="color:#7f8c8d;font-weight:bold;">DEC</span> <span style="color:#7f8c8d;font-weight:bold;">DISPOSE</span> <span style="color:#7f8c8d;font-weight:bold;">EXCL</span> <span style="color:#7f8c8d;font-weight:bold;">FLOAT</span> <span style="color:#7f8c8d;font-weight:bold;">HALT</span> <span style="color:#7f8c8d;font-weight:bold;">HIGH</span>
<span style="color:#7f8c8d;font-weight:bold;">INC</span> <span style="color:#7f8c8d;font-weight:bold;">INCL</span> <span style="color:#7f8c8d;font-weight:bold;">MAX</span> <span style="color:#7f8c8d;font-weight:bold;">MIN</span> <span style="color:#7f8c8d;font-weight:bold;">NEW</span> <span style="color:#7f8c8d;font-weight:bold;">ODD</span> <span style="color:#7f8c8d;font-weight:bold;">ORD</span> <span style="color:#7f8c8d;font-weight:bold;">SIZE</span> <span style="color:#7f8c8d;font-weight:bold;">TRUNC</span> <span style="color:#7f8c8d;font-weight:bold;">VAL</span>


<span style="color:#7a7c7d;font-style:italic;">(* unsafe facilities *)</span>

<span style="color:#7a7c7d;font-style:italic;">(* module *)</span>

<span style="color:#da4453;font-weight:bold;">SYSTEM</span>

<span style="color:#7a7c7d;font-style:italic;">(* types *)</span>

<span style="color:#da4453;font-weight:bold;">ADDRESS</span> <span style="color:#da4453;font-weight:bold;">WORD</span> <span style="color:#da4453;font-weight:bold;">PROCESS</span>

<span style="color:#7a7c7d;font-style:italic;">(* procedures *)</span>

<span style="color:#da4453;font-weight:bold;">ADR</span> <span style="color:#da4453;font-weight:bold;">NEWPROCESS</span> <span style="color:#da4453;font-weight:bold;">TRANSFER</span> <span style="color:#da4453;font-weight:bold;">TSIZE</span>


<span style="color:#7a7c7d;font-style:italic;">(* number literals *)</span>

<span style="font-weight:bold;">CONST</span>
  n = <span style="color:#f67400;">1000</span>; r = <span style="color:#f67400;">1.234</span>; x = <span style="color:#f67400;">0FFFFH</span>; c = <span style="color:#f67400;">077C</span>;


<span style="color:#7a7c7d;font-style:italic;">(* quoted literals *)</span>

<span style="font-weight:bold;">CONST</span>
  apostrophe = <span style="color:#f44f4f;">&quot;'&quot;</span>; doublequote = <span style="color:#f44f4f;">'&quot;'</span>;
  single =<span style="color:#f44f4f;">'foobar'</span>; double = <span style="color:#f44f4f;">&quot;bazbam&quot;</span>;


<span style="color:#7a7c7d;font-style:italic;">(* sample code *)</span>

<span style="font-weight:bold;">TYPE</span> Foo = <span style="font-weight:bold;">RECORD</span>
  bar : Baz;
  bam : Boo
<span style="font-weight:bold;">END</span>; <span style="color:#7a7c7d;font-style:italic;">(* Foobar *)</span>


<span style="font-weight:bold;">VAR</span>
  foo, bar, baz : <span style="color:#2980b9;font-weight:bold;">CARDINAL</span>;


<span style="font-weight:bold;">IF</span> foo &gt; bar <span style="font-weight:bold;">THEN</span>
  baz := bam
<span style="font-weight:bold;">ELSE</span>
  baz := boo
<span style="font-weight:bold;">END</span>;


<span style="color:#7a7c7d;font-style:italic;">(* EOF *)</span>
</pre></body></html>
